#include <bits/stdc++.h>
using namespace std;
class Tnode{
public:
    int data;
    Tnode* pLchild;
    Tnode* pRchild;
    Tnode(int d,Tnode* l = nullptr,Tnode* r = nullptr){
        data = d;
        pLchild = l;
        pRchild = r;
    };
};
bool isSymmetrical(Tnode* root1,Tnode* root2)
{
    if(!root1&&!root2)
        return true;
    if(!root1||!root2)
        return false;
    if(root1->data != root2->data)
        return false;
    return isSymmetrical(root1->pLchild,root2->pRchild)&&isSymmetrical(root1->pRchild,root2->pLchild);

}
bool isSymmetrical(Tnode* root)
{
    if(!root)
        return false;
    else{
        isSymmetrical(root,root);
    }
}

int main() {
    Tnode* a = new Tnode(3);
    Tnode* b = new Tnode(4);
    Tnode* c = new Tnode(4);
    Tnode* d = new Tnode(6);
    Tnode* e = new Tnode(7);
    Tnode* f = new Tnode(7);
    Tnode* g = new Tnode(6);
    a->pLchild = b;
    a->pRchild = c;
    b->pLchild = d;
    b->pRchild = e;
    c->pLchild = f;
    c->pRchild = g;
    isSymmetrical(a)?cout<<"对称":cout<<"不对称";


    return 0;
}